﻿# -*- encoding: utf-8 -*- 
from itertools import groupby
from datetime import datetime, timedelta

from odoo import api, fields, models, _
from odoo.exceptions import UserError
from odoo.tools import float_is_zero, float_compare, DEFAULT_SERVER_DATETIME_FORMAT
from odoo.tools.misc import formatLang

import odoo.addons.decimal_precision as dp

class FHsaasMK_FHsaasTB(models.Model):
    _name = 'FHsaasMK.FHsaasTB'
    _description = u'FHsaasZW'
    #_rec_name='FClass'
    def get_employee(self):
        obj = self.env['hr.employee']
        idsobj = obj.search([('user_id','=',self.env.user.id)])
        print('-------------------------------------')		
        print(self.env.user.id)		
        #print(ids)	
        res = idsobj.read()
        print(res)					
        return res and res[0]['id'] or 0	
FHSAAS_columns  
					   


	
	
    @api.model		
    def create(self, vals):
        result = super(FHsaasMK_FHsaasTB, self).create(vals)	
        return result
    @api.multi		
    def write(self, values):
	    
        result = super(FHsaasMK_FHsaasTB, self).write(values)		
		
        return result
    @api.multi
    def unlink(self):
	
        return super(FHsaasMK_FHsaasTB, self).unlink()
    @api.multi
    def copy(self, default=None):
        return super(FHsaasMK_FHsaasTB, self).copy(default)
    @api.multi
    def search(self, args, offset=0, limit=None, order=None, context=None, count=False):
        domain =None		
        domain = [('state', '=', '0')]		
        return super(FHsaasMK_FHsaasTB, self).search(args, offset=offset, limit=limit, order=order, count=count)

		
FHsaasMK_FHsaasTB() #对象定义结束
